package binarySearchTree;

public class BinaryNode<T> {
    // Constructors
    BinaryNode( Comparable<T> theElement ) {
        element = theElement;
        setLeft(right = null);
    }
    
    public void setLeft(BinaryNode<T> left) {
		this.left = left;
	}
	public BinaryNode<T> getLeft() {
		return left;
	}
	
	public void setRight(BinaryNode<T> right) {
		this.right = right;
	}
	public BinaryNode<T> getRight() {
		return right;
	}
	public <T>Object getElement(){
		return this.element;
	}
	
	
    Comparable<T> element;      
    private BinaryNode<T> left;         
    BinaryNode<T> right;       
}